package by.grsu.hdm.media;


import by.grsu.hdm.exceptions.IllegalInternalStateException;
import by.grsu.hdm.media.format.audio.IMp3;
import by.grsu.hdm.media.format.audio.IWav;
import by.grsu.hdm.media.format.video.IAvi;
import by.grsu.hdm.media.format.video.IMkv;

public class MiniMediaPlayer extends MediaPlayer implements IMp3,IWav,IAvi,IMkv{

	String format;	
	
	
	public MiniMediaPlayer(){}
	
	public void playMp3(){
		this.format="Mp3";
		try {
			play();
		} catch (IllegalInternalStateException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
	
	public void playWav(){
		this.format="Wav";
		try {
			play();
		} catch (IllegalInternalStateException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
	
	public void playAvi(){
		this.format="Avi";
		try {
			play();
		} catch (IllegalInternalStateException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
	
	public void playMkv(){
		this.format="Mkv";
		try {
			play();
		} catch (IllegalInternalStateException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
	
		
	public String getFormat(){
		return this.format;
	}
}
